Pfhorte Documentation
Version 1.0
by Randy Varnell email rvarnell@macromedia.com
and
Creator of Pfhorte!
Steve Israelson

with special thanks to
Robert Hust, Jonathan Allen, Peter Bengston
Outline
I.     Introduction
II.    Installing Pfhorte
III.   Palettes
	Tool Palette
	Defaults Palette
	Altitude Palette
	Inspector Palette
	Levels Palette
	Map Palette
IV.  Menu Items
	File Menu
	Edit Menu
	Levels Menu
	View Menu
	Magic Menu
V.   Building in Pfhorte
	Some Basics
	Polygons are our 'Friends'
	Pseudo 3-D Smoke and Mirrors
	Scale & Units of Measure
	Editing Walls
	Types of Polygons
	Drawing Modes
	Textures
	Objects
	Aliens
	Lighting
VI.  Scripting in Pfhorte!
VII. Appendices
	Appendix I Misc. Marathon Engine Limitations
	Appendix II  General Tips
VIII. Legal Junk

Introduction
Build Rome in a day?  Well, maybe not Rome, but what about a coliseum.  Or a temple.  Or a space station.  You can do all this in several hours with the aid of Pfhorte!, a full-functional map and object placement editor for Marathon.
So you've been playing Marathon for several months now, and you're tired of the same old maps.  "What fun it would be," you think, "to create my own maps with treacherous rooms, more equipment, and Pfhor, Pfhor, Pfhor!"  
Now, here's your chance... 

NOTE Please e-mail Randy about any documentation issues, not Steve I. 
Installing
To install, simply copy Pfhorte to your hard disk.  You MUST also make a copy or an alias to the shapes file from marathon and put this copy or alias into the same folder as Pfhorte.  This file must be called "Shapes".
If you have a powerPC, you may need the power PC libs.  Copy these to your extensions folder.
Palettes
Tool Palette
There are six tools in the Pfhorte! tool palette
The Arrow Tool is used for dragging objects, points and polygons around.  Just click on an item and drag to move it.  You can select items by just clicking on them.  
Holding 'option' down while clicking on things does some special stuff.  For objects, it allows you to drag a line indicating the direction the object is facing.  For platform switches, it allows you to drag a line to the platform the switch controls.  For teleporters it allows you to drag out the destination of the teleporter.  When the platform switch is a switch control that appears on a wall, option click on the wall and drag to the platform the switch controls.  
When you click on a teleporter, or platform switch, a line will be drawn to show you what this thing refers to.
Dragging objects outside of a poly will delete them, since it is illegal to have objects or notes outside of polys.
The Object Placement Tool allows you to create a new object.  Just select the Object Placement tool and click in the polygon that you want the object to appear in.  A dialog box will automatically pop up allowing you to set the type of object and several other characteristics.  See the section on Objects for further details.
Note Clicking with this tool will automatically place the same type of object as the last one you placed unless you change your selection.
The Polygon Tool allows you to create polygons (rooms).  Be sure to set up the defaults palette before trying to use this tool.  Simply click points in a clockwise direction until you have the shape you want.
If you click more than 8 points or make a concave polygon, then the poly you are creating will be broken up into individual connected polys to make that shape.
To make a polygon connected to another, be sure two of the points you click are two of the points in the other polygon.  The points will show purple if they are connected. 
The Note Tool allows you to put notes in your map.  These show up when the players choose the Map mode in the game.  Just click on the poly in which you want the note to appear.  
Dragging notes outside of a poly will delete the note, since it is illegal to have notes outside of a poly.
The Magnifying Lens Tool allows you to zoom in to the point you click on.  To zoom out, hold down shift.  To zoom in and out by a larger amount, hold down option.  
The Magic Wand Tool will set a polygon to the current settings shown in the Defaults palette when you click on the polygon.  Holding 'option' down will set the defaults to be the same as whatever polygon you have selected.
Double clicking on the magic wand tool allows you to change its settings.  This lets you set what poly attributes the wand will affect.
The Lighting Tool does the same thing as the magic wand tool, except it works on lighting levels in the polys.
Defaults Palette
This palette allows you to set the default values that polygons will have when they are created.  You can set the textures for the floor, ceiling and walls,  and you can also set the default floor and ceiling heights.
Power Tip  The map making process works best if you set the values in the palette before you begin drawing polygons, or even before you open a new map.  
The Defaults Palette is best used when creating several polys with similar or identical characteristics.  When you are working on a group of rooms which have the same floor and ceiling heights, the same textures on wall, ceiling, and floor, and have the same light levels, set the default palette before you start the group, draw all the polys, and do the detail editing afterward.
Changing the default palette after the poly has been drawn does not alter that poly, nor any created before it.
Altitude Palette
This is the tall, thin blue palette with a shorter green bar inside the blue field..  This palette allows you to specify the altitude range of your immediate work area.  The blue area indicates the minimum and maximum height floor and ceiling that will be shown or clicked.  The green area indicates the minimum and maximum heights which are currently used in polygons in your map.
You can drag the dark blue bars on the top and bottom of the palette to limit the map view to a particular range of altitudes.
The altitude Palette is very useful when working on areas that are directly above or below other areas.
Inspector Palette
The Inspector Palette displays the current values of a selected polygon, line, or object.
For polygons, the Inspector Palette displays current polygon type, floor and ceiling altitudes, floor and ceiling light levels, and floor and ceiling textures.  Also, for platforms, a button appears on the Inspector Palette allowing you to bring up the Edit Platform dialog box.
For objects, the Inspector Palette displays current object category, object type, maximum number, minimum number, and frequency.
For lines (walls), the Inspector Palette displays the textures on each side of the line (wall), and the drawing mode for each of them.
These categories will be further discussed on the sections dealing with polygon editing and the section on object editing.
Levels Window
The Levels Window appears when you create a new Map pack or open an existing one.  The Levels Window displays the name of all the levels which are in one pack.  These levels can be separate network play type levels, or they can be a series of levels in a solo game, or any combination thereof.  Each level has a particular mission that must be accomplished along with a soundtrack and a texture set to use.
This information can be changed in the mission info dialog that you can open up when you have a level open for editing.
By double-clicking on a level name, you can open that level on the Map Window and begin editing.  Multiple Levels Windows may be opened at the same time, and levels may be cut from them, copied from them, or pasted to them.
Power Tip If you want to make a special Map pack containing only levels you pick, first create a 'new' map pack by selecting "New Map" in the File menu.  Then, 'open' an existing map pack (or packs) with the levels you desire to add to your new pack.  Click once on the level you wish to move, and select 'Copy' from the Edit menu. Now, click anywhere on the 'new' Levels Window and then select ''Paste" from the Edit menu. The old level now appears in the 'new' Levels Window.  Be sure to save the new palette before quitting Pfhorte!.
Map Window
The Map Window is where the real action occurs!  This palette appears when a level is selected from the Levels Window.  The Map Window defaults to a six-inch palette with a blue grid over a gray background inside.  However, you may resize the palette to fit your desired work area.  You may also change the colors and appearance of the background and the grid by selecting 'Preferences' from the File menu.
Menu Items
Following is a list and description of all the menu choices you have in Pfhorte.
File Menu
New Map  Creates a new Map pack.  When you select this command, a new Levels Window appears called 'Levels'.
Open  Open an existing Map pack
Close  Closes the currently selected Map pack.
Save  Save the currently selected Map pack under the current name and location.
Save as  Save the currently selected Map pack under a new name and/or new location.
Special Note  After performing a 'Save as', you need to close and then re-open your Map pack to keep it from becoming corrupted.
Revert  Restores a selected map pack to the previously saved version.  This selection erases all changes made since the map pack was last saved.
Page Setup  Allows you to determine how the page will be setup when printed.  You can choose orientation, scale, and paper.
Print  Prints the currently selected map exactly as it is displayed on screen.
Print One
Preferences  The preferences allow you to customize the Pfhorte! work environment.  In the preference menu, you can change the default colors for specific types of polygons, items, and characters.  You can also set grid, line, and point size. 
Quit  Exits Pfhorte!
Edit Menu
Undo  Currently, using the Undo command will undo the last polygon or point drag you made.  In the future, this feature will affect many more functions.
Cut  Deletes a selected polygon or level and saves it to the 'clipboard'.
Copy  Makes an unseen copy of a selected polygon or level on the 'clipboard'. 
Paste  Places a copied polygon on the Map Window, or places a copied level on a selected Levels Window.
When polygons are copied then pasted, the pasted poly will appear slightly down and to the right of the copied poly.  Be careful when doing this because it can sometimes be difficult to move the pasted polygon to a new location, depending how 'dense' the area is with polys and objects.  
Power Tip  When making many copies of the same poly, a good solution is to make an initial copy, and move that copy to the edge of the map window.  Then, copy that polygon and move the new ones into place from outside a 'dense' area.
Note  At the present time, only the basic outline of the polys will be copied, not the poly's characteristics.  Any settings, objects, or connections to other polys will not be copied when performing Cut and Paste operations.
Clear  Functions the same as hitting the 'delete' key.  It erases any selected polys or objects.
Select All  Selects all polys on the Map Window.
Show Clipboard  Opens a window showing the contents of the Mac clipboard.
Get Info...
Save Current Settings  This will save your menu settings, and the current size and position of the palettes.  When a level is open, the size and position of its Map Window will also be saved, so that when that level is opened again, the Map Window will appear as it was saved.
Edit Map Info  When you have a map file open, this dialog allows you to set the name for the entire map file.
Edit Level Name  Opens a dialog which allows you to change the name of the currently selected level.
Delete Level  Deletes the currently selected level.
Levels Menu
These selections work only on the front most Map Window.
New Level  Adds a new, empty and unnamed level to the currently selected Map pack.
Edit Mission Info Data  When you have a map file open, and a level open, this dialog allows you to change the various mission-specific parameters.  You should set these BEFORE you start making your level, since changing the texture set will affect your entire level.  Here's what you can set
Texture Set  Enter the number of the texture set  from the current shapes file to be used in this level.
Physics Model  Enter the number of the Physics Model to be used with this level.
Song Track  Enter the number of the song from the Music file to be played on this level.
Mission Goals  Select some, none, or all of the follow goals to modify your level's mission.
Multi-Player Carnage  Kill all you friends in a network game.  Be sure and check this box for levels you design specifically as 'net levels'.
Single Player  This level can be played as a solo game.
Multi-Player Cooperative
Extermination  You must exterminate all the aliens before you can exit the level.
Vacuum  This level has been proclaimed oxygen free!  Your oxygen supply will gradually diminish, unless you use an Oxygen control panel.  You should probably be sure that one of these control panels is available.  Unless your really nasty.
Also, only phasers will work on this level.
Exploration  You must explore polygons set to Must be Explored to be able to exit this level.
Magnetic  This setting causes your motion sensor to malfunction.
Retrieval  You must find an object and pick it up to be able to exit this level.
Rebellion  Causes the compilers to fight with the Pfhor.
Repair  You must obtain a repair chip and use it on the defined objective to be able to exit this level.
Low Gravity  Low gravity makes everything, including projectiles, drop much more slowly, as you would expect.
Rescue  You must release trapped BOBs to be able to exit this level.
The most important part of the mission info is choosing which texture set to use.  This is important because it affects what types of scenery and aliens you can have in that level.  Certain scenery elements and aliens only work with certain texture sets.  Also, only certain types of control panels will work with certain texture sets.  This is a big cause of problems for novice map makers.
Edit Lighting Types  When you have a map file open, and a level open, this dialog allows you to add new lighting types and to edit existing ones.  To add a new lighting type, just click the "Add new light type" button and a new light type will be created.  You can also select an existing light type to edit by selecting it with the popup menu.
For more information about lighting in Marathon, look in the Lighting section of the Pfhorte! documentation.
Edit Object Placement Data  Brings up a dialog which allows you to edit the overall characteristics of objects on the currently open level.  For more information on editing objects, see the section on 'Objects'.
Edit Authors Name  Allows you to change the author's name for the currently selected level.
Center Map  Choosing this will move your entire map to the center of the world (not our world).  This is useful for those who fail to plan ahead (who plans ahead anyway?) and run out of room at the edge of your map.
Align Textures  Choosing this command automatically aligns all textures vertically.  This is most noticeable in places where the floor or ceiling height changes, and 'stacked' textures show.
You can prevent textures from being aligned by selecting 'Don't Align Textures' in the Side Editor dialog.

View Menu
Show Points  Toggles display of the points on the Map Window.
Show Lines  Toggles display of Lines on the Map Window.
Show Objects  Toggles display of Objects on the Map Window.
Show Notes  Toggles display of Notes on the Map Window.
Show Grid  Toggles display of the Grid on the Map Window.  Grid size and color may be defined in the 'Preferences' selection in the File Menu.
Snap to Grid  When checked, newly created points will automatically move, or 'snap',  to the nearest Grid point.  When unchecked, newly created points will appear exactly where you place them.
	Snap to Grid is useful when creating perfect squares, or multiple similar polygons.
Show Grid Behind  When selected, forces the grid to appear behind polygons and objects.  Otherwise, the grid appears behind everything except polys.
Show Poly Lighting  When selected, the inside color of the polys will reflect their set lighting type.
Show Poly Floor Heights  When selected, the inside color of the polys will reflect their different floor altitudes..
Show Poly Ceiling Heights  When selected, the inside color of the polys will reflect their different ceiling altitudes.
Show Poly Types  When selected, the inside color of the polys will reflect their type, as set in the 'Preferences' under the File Menu.
Normal Poly Drawing  Displays all polys with a default interior color, as defined in the 'Preferences.'
Show Bad Polys  When selected, polygons which cannot be correctly interpreted by Marathon's engine will be displayed as the color defined in the 'Preferences.'
Do Not Auto Split New Polys  When selected, newly created polys with more than eight points will simply not appear.  When this item is left unselected, newly created polys with more than eight points will be split into two or more attached polys.
Show Defaults  Opens the Defaults Palette.
Show Altitudes  Opens the Altitude Palette.
Show Inspector  Opens the Inspector Palette.
Show 3D View  Opens the 3D View Palette.
Zoom In/Out  Allows you to magnify the view of the Map Window for detailed editing, or pull back to get the big picture.
Hide Selected Polys  This will cause any selected polygon to not be displayed on the Map Window.
Show All Polys  This causes all 'hidden' polys to reappear on the Map Window.

Magic Menu
This menu contains many shortcuts for building your level.  To use most of them you must have a line selected.  In most cases, they will create a small polygon connected to that line and put the appropriate control panel on the outside wall for you.  For a more specific description of what each of the items in this menu do, see the section on 'Editing Polygons."
Detach Polygon  Unjoins a polygon from all polygons that it is joined to.
Attach Polygon  Attaches a polygon to other polygons.  Only end points of lines that are over end points of other poly's lines will get attached.
Split Line  Creates a point exactly in the middle of the selected line.
Make <item>  Door, Hallway, Oxygen Panel, Recharge (1,2,3)x Panel, Light Switch, Platform Switch, Pattern Buffer, Terminal, Alien Recharge (2,3), Alien Platform Switch, Alien Pattern buffer
Make Staircase  Creates a staircase out of a selected polygon.  The number, distance, and turn of the staircase is determined by selections in the 'Stairs' box on the Defaults palette.
Building In Pfhorte!
Some Basics
Using Pfhorte! is very similar to drawing in one of the popular 'vector graphics' drawing programs used by graphic's professionals--like Macromedia FreeHand, Adobe Illustrator, or Corel Draw!.  All your drawing is based on 'points' and 'lines'.  
When you select the Polygon Tool, and click once on the Map Window, a point appears where you click.  Moving the mouse after you create a point will show an elastic 'line' which follows your mouse around the screen, growing and contracting in relation to the first point.  When you click a second time, the line between the first two points solidifies, and you again have control of an 'elastic' line anchored at the second point you created.  This process is repeated until you double-click, or until you click on the original point.  When you do that,  you've created a very important element of Marathon mapa polygon!
Polygons are our 'friends
Marathon's basic "building block" is the polygon (or 'poly', as you've probably already gathered). Every map is made up of dozens and dozens of polygons connected together to make hallways, rooms, etc.
Because of the way Marathon's engine operates, a Map is designed in 2D. You cannot "model" a three-dimensional room by creating a 3D cube and sticking other 3D cubes onto it or inside it, as you would in a 3D program like InfiniD or Ray Dream Designer. Instead, you create polygons outlining a room's boundaries, or walls. You then tell Marathon the height of the floor and the height of the ceiling. You link these polygons together, creating pseudo-3D structures by defining different floor and ceiling heights.
Ledges are simply polygons whose floor heights are higher than the rest of the room. Staircases are hallways whose floor heights go up or down... Platforms and doors are "special cases"regular polygons whose ceiling heights and floor heights can change dynamically.  A door, for example, is just another 2D polygon in a map, connecting two larger rooms. But when you are playing the game, and you walk up to a 'door', and hit the action key, its ceiling height changes and it appears to slide upward, allowing you to pass.
Polygons must always have between 3 and 8 sides.  They also must be drawn in a clockwise fashion, and in such a way that all interior angles are less than or equal to 180 degrees and greater than 15 degrees.
Fortunately, polygons can be connected together along their sides.  Only two polygons can be connected together along any one side.  This means that you cannot have a room connecting along one wall and another room or window higher up on that same wall.  When two polygons are connected, the wall between them is not drawn so that the player can walk and shoot between rooms.  If the floor height or ceiling height of the polygons are not the same, then small walls will fill in those gaps and still leave an open area connecting the polygons.  This is how stairs or windows are made.
Each polygon also has a separate floor light and ceiling light.  For more explanation on lighting types, and how to set them, see the section on 'Lighting'.  Pfhorte allows you to make polygons with more than 8 points and it will automatically split this polygon up into smaller connected polygons for you.
Double clicking on a polygon brings up the Edit Polygon dialog.  You can change the type of polygon and also change other various info about it.  A small image of the polygon is shown with each side numbered.  For sides that have walls you can click on the edit button for that wall to bring up the side editor dialog.  You can also click on the 'Solid' check box to have a non-existent wall (window) repel shots.
Pseudo-3D Smoke and Mirrors
"But wait," you cry! "That sounds like the way DOOM does things! I thought Marathon's engine was superior to Doom's, able to do 'real' 3D maps!" You're right, partially. Marathon is capable of creating maps with rooms on top of one another. But it's all smoke and mirrors.  Understanding that is the key to understanding map creation.
Picture a flat map, with no elevation changes. It's shaped like a big "U". 
      _______________     
     |               |      
     |    _______    |      
     |   |       |   |        
     |   |       |   |       
     |   |       |   |         
     |   |       |   |        
     |___|       |___|      

If you twist one side of the "U" around, so that it overlaps the other side, you will have two polygons that occupy the VERY same space in the "world."
      _______________         
     |               |       
     |    _______    |        
     |   |       |   |     
_____|___|_______|   |    
     | X |           | <-- 'X' indicates overlapping area
_____|___|___________|              
     |___|  
                       
However, when you open that map in Marathon, you won't see the second hallway when you're in the first one. They are two separate "rooms," even though they occupy the same space in Marathon's "universe."
What happens when you change the elevation of one of those rooms, though? Suddenly, you have two rooms that are on top of each other as far as play is concerned. Although the actual map defines them as 2D spaces that overlap, the Marathon engine turns them into 3D rooms on different "floors" of a structure.
Scale and Units of Measure
Your character is roughly 819 units tall. Making rooms shorter than this will keep your character from entering those rooms normally.  The highest you can normally step (for stairs, etc.) is around 345.  I say normally in all my size quotes because by playing with the physics editor you can change a number of these constants.
Some Statistics(default physics file*)
Highest step you can make 345 (340-345)
Lowest ceiling height you can enter 819
Texture Block Width x Height 1024x1024 
Note  These statistics are true only for the default  Physics Module.  Any editing you do to a physics module can affect all these parameters.
Types of Polygons
These are the various types of polys which can be used in Marathon.  You can set the type of the poly in two placed  the Edit Polygon dialog (brought up by double-clicking on the poly), or the Inspector palette (when a poly is selected).
Normal  This is your average hunk of floor/ceiling etc.
Item Impassable  You cannot shoot through this polygon.  Great for making windows.
Monster impassable  Monsters generally stay out of these squares.  They will follow you through them, however.
Major Damage  Will cause very rapid damage to a player in this poly, and will make it difficult to see.
Minor Damage  Will cause slow damage to a player in this poly, and will make it difficult to see.
Platform  A door, elevator, trash compactor, etc. See the section on Platforms for more information.
Light on/off  Sets a poly so that stepping in it will turn a light on or off.  Option-drag on a poly with this setting to define the poly whose light level is affected.
Platform on/off  Sets a poly so that stepping on it turns a platform on or off.
Teleporter  Will send you some where else only if you stop on this poly.  If you keep moving, you don't transport.
You can Option-drag on this poly to determine the destination poly of your teleport.
Glue Trigger and (Super) Glue  These settings are used to set triggers, which activate aliens, or boundaries for triggers, defining which aliens you activate.
First of all, when a player crosses a polygon set as a Glue Trigger, that trigger emits a 'signal'.  Glue Trigger 'signals' propagate not in a radial fashion (like ripples on a pond) but from polygon to polygon, following all possible paths around your map. Differences in height between the polys do not matter. As long as a poly is connected to another polygon, Glue Trigger signals will be sent from one to the other.
However, a SuperGlue polygon will block the signal. By "sealing" the exits from an area using SuperGlue polygons you can limit the effect of a Glue Trigger. In this way, you can have as many glue-triggered areas as you like.  Be sure, for best results, that no aliens are placed directly on the SuperGlue polys.
Example  If you look at the area where the machine gun is found on level 2 of Marathon, you'll see a very good example of Glue Trigger and SuperGlue. The Glue Trigger that activates the aliens in the machine gun room is surrounded on either side by SuperGlue polygons, to prevent anything else from being triggered.
(Consequently, if you don't put in any SuperGlue polygons, or if you fail to block all possible exits from the triggered area, a Glue Trigger will affect all Glue polygons in your map.)
Secondly, the Glue polygons absorb the "alert" sound that the aliens make.  This sound, too, will be sent from alien to alien, and if you are not careful you might end up with all aliens on the level suddenly coming after you. Glue polygons will "muffle" this the alien alert sound, in exactly the same way as SuperGlue polygons "muffle" the Glue Trigger.
This means that you can use Glue polygons to seal off a battle area. Glue polygons placed at the exits of the area will prevent other aliens from noticing what is going on, with one exception if they can see what's happening, they will come anyway.
Here's a good example of what use of a Glue polygon might look like
       +------------------------+
       |                        |
+------+                        |
| Y   G            P            |
|    +-+                        |
|    | |                   Z    |
|    | +------------------------+
|    |
|  X |   (P=Player, X,Y,Z=aliens, G=Glue)
If G is a Glue Square, then X and Y won't hear the call of Z. However, You can see the player, P, and therefore will enter the room and attack, possibly also alerting X, who will follow Y into the room to attack P. If Y is removed altogether, then X won't activate until P leaves the room and enters the corridor.
Glue polygons are used over and over again in the Marathon map to subdivide a level into a neat sequence of smaller battles. A good example is the level mentioned above. For instance, on one side of the SuperGlue polygons near the machine gun is a Glue polygon whose sole task is to keep the two aliens in the next room where they are until the player enters their room.
Must be explored  When Exploration is checked as a goal in the Mission Info dialog, this (or these) polys must be crossed by the player to be able to exit the level.
Exit  Going to a polygon with this setting after completing the goals for this level will teleport you to another level.  The level you are teleported to can be entered in the Edit Polygon dialog box (which can be reached by double-clicking on the 'exit' polygon).
Drawing Modes
These are various settings which affect how the textures which make up a polygon are drawn or animated.  They are as follows
Normal
Fade to Black
Invisible
Sub Invisible
Pulsate
Wobble
Fast Wobble
Static
Sub Static
Landscape
Smear
Fade-Out Static
Fold-In
Fold Out
Horizontal Slide
Fast Horizontal side
Vertical Slide
Fast Vertical Slide
Wander
Fast Wander
Editing Walls
From the Edit Polygon dialog you can get to the Wall Information dialog.
Here you can set up the various characteristics of the wall.  If you want this wall to have a control panel on it, you can check one of the three control panel check boxes and set up the control panel.
Type
Control Panel Type
Permutation
Direction
Control Panel Status
Control Panel
Repair Switch
Primary
Secondary
Transparent
Don't change texture alignment
Textures
There are 6 marathon resources for textures, 1 is the Pfhor ship, 3 are the marathon, and 2 are the interfaces for the marathon and the alien ship (rechargers etc.).  You must choose one of the first 4 sets as your pallet of textures to choose from.  The interface textures are handled in the side dialog boxes as a special case.
Walls use up to three textures and one time.  All walls, except a split wall, only use the primary texture.  The split type wall, with a window in it, uses the secondary texture as well for the lower half of the wall.  The 'Dont Change Texture Alignment' option forces Pfhorte to leave the texture alignment the way you have it set when you do an align textures command.  This is so that if you make a control panel and set the xo and yo values to show the correct panel, then Pfhorte won't change it by mistake.
Full The wall fills the whole side of the polygon.
Low The wall fills the lower portion of the side of the polygon
High The wall fills the upper portion of the Side.
Split Wall fills upper and lower portion, leaving out middle section (window), if no appropriate adjacent polygon then same as Full. 
Composite Crashes so far.  If you get it to work e-mail me!
Shifting the Texture Reference Point, the x0 and y0 fields
The reference point for shifting a poly is the upper right hand corner.  This is where the texture's x and y 0,0 point is.
Now, think way back (or ahead) to that geometry class. from your high school years.  X was vertical, and the y axis was horizontal.  Now think about those lovely programmers at Bungie.  Unfortunately (for those of us who experience the miracle of remembering geometry) Bungie has rotated the graph 90' counterclockwise.  So now the x axis is left and right (positive being left, negative to the right).  The y axis  is up and down, positive being up and negative being down.  To summarize
X0 shift the texture + left,or  - right
Y0 shift the texture + up, or - down
Primary texture  This is texture which fills the wall, unless you select a secondary texture.
Secondary texture  This setting is for when you split your walllike for having a window in the middle. The secondary texture would be the texture below the window, while the primary texture would be above the window.  The second set of y and x's is for shifting your Secondary texture.
The unit of measure for these offsets is the same unit used in the rest of map editing.  So if you raise part of your ceiling by 300, and offset your wall texture by y0-300 your whole wall will have textures that line up (vertically that is).   A texture block is 1024 units tall/wide, so if you put a texture on a wall 1024 units high you will get one texture up and down with no overlap.
You can also choose the Align Textures command from the Levels menu to automatically align textures vertically or horizontally.
Aligning control panel Textures
When aligning textures on a control panel, here are the alignment settings for each type of control panel
1x charger no offset
2x charger x512
3x charger y512
Oxygen x and y 512
Comm Panel Offset of y512
Save Panel No Offset
Alien 2x No offset
Alien 3x y512
Alien Save Panel No offset 
Your average switch and recharge panel is 512 units wide and 512 tall.
The Comm and Save panels are 512 units tall and 1024 wide.
To get the textures for the various panels you need to offset the primary texture.
The Alien Save Panel is a full size texture 1024x1024, and the Alien rechargers are 1024x512.
Changing Textures in the Shapes file
If you're really a Marathon map editing stud, and start changing shapes in the Shapes file, there are some things you need to know to get maximum benefit from Pfhorte!. 
The first time you load Pfhorte!, the program scans the Shapes file that is currently in the Pfhorte! folder and builds a 'Pfhorte.cache' file containing, among other things, the textures which appear in the dialog boxes of the program.
To allow Pfhorte to 'see' your new textures you must first remove the old shapes file from the Pfhorte folder, and place your new one in.  Then, you must delete the Pfhorte.cache file from your Preferences folder.  This forces Pfhorte to build a new cache file, and will cause your new shapes to appear in the texture selection fields in Pfhorte's dialog boxes.
Platforms
Probably one of the hardest things to do in Marathon map editing is to correctly setup a platform.  Platforms are also one of the most useful and important elements in a map.  So, without further ado, let's see if we can't learn how to hack platforms!
When you change a polygon's type to a Platform, you will then be able to bring up the Edit Platform dialog box which allows you to edit all the characteristics of the Platform.  Here's a list of the available selections in the Edit Platform dialog
Types  The types of platforms you may create are
Normal Door
Silent Pressure Switch
Noisy Pressure Switch
Alien Door
Silent Alien Pressure Switch
Noisy Alien Pressure Switch
Initially Active  Platform starts out moving.
Initially Extended  Platform starts out extended.  
If Ceiling is checked, the platform will begin extended from the ceiling to the floor (min. height).  
If Floor flag is checked platform will begin extended from the Floor to the ceiling (max. height). 
If Floor and Ceiling are both checked, the platform begins extended from the floor and the ceiling, meeting at the midpoint of the two altitudes, like the Pfhor Doors.
Stops at each level  Platform will raise or lower, etc. and then stops until activated again by a switch or trigger. Otherwise, it would simply continue moving up and down.
Stops at initial level  Platform will raise, lower, etc. and then return to it's original position before stopping completely.
Floods  When this setting is selected, the floor textures surrounding the platform are mapped onto the platform itself.  This in effect hides the platform, or can be used to give the effect that the platform is submerged, say, beneath a pool of lava.
Floor to ceiling  Platform height extends from adjacent floor to adjacent ceiling.  This is a good setting for quickly creating a door that has the same height as the poly it is attached to.
Floor  Platform extends up from the floor.
Ceiling  Platform extends down from the ceiling.
Causes damage  The platform can cause crushing damage to anything stuck between it and the floor or ceiling as it extends.  What a wonderful idea for a death trap!
No activate parent  When platforms are activating each other by using Activate Adjacent, the platform that first activated all the others is not itself activated by an adjacent platform.
One shot  The platform may only be triggered once, and then remains inactive for the rest of your time on that level.  This option is useful for creating 'stairs' that you have to activate from a remote trigger in order to reach a goal.
Activates light  Activating this platform activates the light for this platform.
Deactivates light  Activating this platform turns off its light.
Player controllable   You can activate the platform (using your action key).
Monster controllable  The monsters can activate the platform (Bob's are NOT monsters, regardless of what you may think)
Safety  You can reverse the door mid-action-if it is opening you can start it closing again, and vice versa.  This is great for keeping doors closed when monsters are trying to open it, and is also particularly nasty in net play when someone has just launched a missile or grenade at you from the other side of the door.
No external activate  Once a platform is activated, only it can turn itself off.  Basically that means that the platform will stop according to its other settings.
Uses native heights  This sets the floor and ceiling heights of the platform to whatever the floor and ceiling heights originally were for the polygon.
Delays before activate  Causes a platform to wait a specified amount of time after activation before it moves.  The Delay time may also be set in the Edit Platform dialog by choosing a verbal degree of speed (fast, slow, etc.) or by entering a numerical value for the speed.
Contracts slow  Causes the platform to return to its original state very slowly.
Activate/deactivate Adjacent on Activating/Deactivating  These options allow you to set the activation or deactivation of a platform to activate or deactivate an adjacent platform.
Basically, if you have several adjacent platforms, you can create a "ripple" effect" of activation, like the Wave in Cold Fusion. Another example is the set of stairs in Bigger Guns Nearby that you trigger with the switch.
Secret  This selection can be used
Speed  How fast you want the platform to move once activated.
You can select this speed by either choosing a degree from the Speed menu (slow, fast, etc.), or you can input a specific number.  Note that if you choose a degree from the menu, the corresponding number is automatically entered.
Delay  How long you want the platform to pause between movements.
You can select this delay by either choosing a degree from the Speed menu (short, long, etc.), or you can input a specific number.  Note that if you choose a degree from the menu, the corresponding number is automatically entered.
Max Height field  Maximum height to which a platform will extend.
This field will automatically display -1 when Floor-to-Ceiling flag is checked
Min Height field Minimum height to which a platform will extend. 
This field will automatically display -1 when Floor-to-Ceiling flag is checked
Note  If creating an elevator 'shaft', its important to set the Max Height field about 900 units lower than the altitude of the ceiling, so that the platform stops with enough headroom for you to exit without one helluva headache!  
Also,do not try to make a platform go higher or lower than the floor and ceiling height in the polygon.  This could cause you map to crash.
Platform example
Make the polygon type 'platform'.  Set the floor height to the lowest height you want the platform to go.  Set the ceiling height to whatever as long as it is higher than the polygon you are going up to plus about 1000.
Check off the boxes for 1) Initially active, 2) Initially Extended, 3) Floor 
	Set Speed to 100
	Set Delay to 200
	Set max. height to -1
	Set min. height to -1
	Set Type to 'Normal Door;
That is all you need for a working elevator that goes from a lower level to a higher level.
Door Examples
Make 2 rooms 2048 units tall, with 1 or 3 thin polygons 1024 units tall between them.  
	Make the middle polygon a platform and check the following
	Initially Extended
	Stops at Initial level
	Floor or ceiling
	Player controllable
	Monster controllable 
	Safety. 
Set the speed to 'Normal' and the Delay to 'Normal'.

Example #1 One-Poly Doorway
Set the Max. Height to 1024,  and Min. height to 0.
Make the texture of the wall connecting the room and the door polygon something that looks like a door.  This door-like texture needs to be in the polygon ADJACENT to the door, not in the door itself.  Do this for the polys on either side of the door.
Make the walls, ceiling and floor of the door polygon underside-of-door looking (like caution stripes, etc.).
You've just made a simple One-Poly doorway!
Example #2  Three-Poly Doorway
Same as one thin polygon except the actual 'door' is the middle of these 3 polygons, the side two serve as the rooms in the section above.
1. Check the Floor to ceiling box, and set the Max. and Min. heights to -1.  This will make the door use the adjacent polygon heights as the max and min.  This kind of door set up tends to look better for tall rooms.
2. Create 3 attached polygons with the same floor and ceiling heights, a narrow one sandwiched between two larger ones.  The narrow polygon will be the door.
3. Double-click the narrow poly to open it.  Change its type to "platform" and click the platform settings button.  A dialog with many check-boxes pops up.
4. Check off "Initially Extended", "Stops at Initial Level", "Floor to Ceiling", "Ceiling", "Player Controllable", and "Monster Controllable".
	"Initially Extended" means the door is SHUT when you first see it.  
	If you don't set this, the door will be wide open and WON'T close when you hit the action key "
5. Set the door speed to 45, and the delay to 120
Now you have a functional door.  Yay.

To make a door go down into the floor instead of up into the ceiling you have to do more than just check off "Floor" on the platform settings.
To make a door that splits & opens both up & down, you have to check off both "Floor" & "Ceiling".
Control Panels
There are several different types of control panels you can place in your map, each allowing you to trigger different events.  The types are as follows
Oxygen  Using this panel will gradually replenish your oxygen supply.  Of course, these panels only matter on levels where no oxygen is available.
Shield 1x  Using this panel will gradually take your shield back to its normal maximum.
Shield 2x  Using this panel will not only fully replenish your shield, it will double it!  After the initial red shield line reaches the top, a second 'boosted' shield line will fill up from the bottom.  It takes as long to fill both these lines on the 2x charger as it does one line on the 1x charger.
Shield 3x  This is the king of all shield chargers!  Using this will take your shield to maximum, then double, then triple!  The triple shield bar is colored purple.  Similar to the 2x, the 3x charger will fill all 3 bars as fast as the one bar on the 1x charger.
Light Switch  Just as you might imagine, this panel allows you to turn the lights of a particular poly (or set of polys) off.
You can choose which poly is affected by the switch by Option-clicking on the light switch poly, then dragging the elastic line to the poly whose lights you wish to turn on or off.
Platform Switch  This switch mat be set to control movement of platforms.  Exactly what this switch does is defined under the Edit Platform dialog.
You can choose which poly is affected by the switch by Option-clicking on the light switch poly, then dragging the elastic line to the poly whose lights you wish to turn on or off.
Pattern Buffer  This is the panel which when used will transport you out of your current level to the next level in the Map pack.
Comm Terminal  When you use this panel, it brings up the Comm Terminal view in Marathon, displaying whatever information you choose to put in here.  The Comm Terminal can include text and graphics, and is the perfect place to give hints or clues to players.  It also is a great tool for building the scenario of you level, or Map pack.
The Comm Terminal can be programmed in the Edit Terminal Message dialog box, which is opened through the Edit Wall dialog when Comm Terminal is selected as the Control Panel Type.
Switch  ???????
Save Panel  Using this panel allows you to save your game.
Alien 2x, Alien 3x, Alien Save Panel, Alien Platform Switch, and Alien Pattern Buffer  These are the same as the 'normal' types of these items, with the exception that their size is different.  See the section on Aligning Control Panel Textures on offsets to use for most of these items.
Of course, in Pfhorte!, the easiest and best way to make control panels is by selecting the wall you want them to appear on, and then selecting the appropriate item from the Magic menu.  This automatically creates a control panel poly and also places and aligns the corresponding texture.
If you're stubborn enough to want to do this by hand (meaning you're probably one of the few people who crave Vegomite), refer to the section on Textures to read about tediously and manually adjusting textures, and offsetting them to fit in the polys.

Objects
Objects are placed in your level by selecting the Object Placement tool, and clicking on a spot within a polygon where you want the object to appear.  When you do so, a small Object Placement dialog box will appear allowing you to choose the type of object you want to place.  Choose the object you want to place and click, 'OK.'  A small colored circle will appear where you clicked, its color representing the type of object you placed.  The representative color may be customized in the 'Preferences' on the File menu.
You may also choose the direction an object faces by entering a degree angle in the Object Placement dialog box.  This, however,  is only useful for aliens, and the player object.  All scenery, weapons and ammo always face towards the player.  If you walk around one of these objects it will appear to rotate to face you.
Power Tip  Another way to define which way a player or monster originally faces is to hold down the Option key, clicking on the object and hold, and drag the mouse to the exact spot you want the object to face. Then release the mouse button.
Objects have several general characteristics which can be defined through the Inspector palette when an object is selected, or by selecting the 'Edit Object Placement Data' from the Edit menu.  The characteristics are as follows
Object Type  Allows you to choose the object you wish to place or modify.
Random Location  If the random box is checked, any new objects which are generated (to replenish the old ones) will be placed randomly throughout the map.  If this is not checked, then objects will only show up in their specified object locations.  
Initial Count  This box shows how many of this particular object appear when play begins on the current level.  Note that this box will update the count on its own for each item of the same type that is placed in the level.
Random Count  This box lets you define how many objects of this type will appear or reappear randomly in the level.
If this box is set to -1, there is no limit to the number of this item which will randomly appear on this level.
Frequency  This setting lets you determine the frequency at which objects will replenish.  The numbere you enter here reflects the percentage at any given moment that objects will reappear after they are used, or after the player holding the object dies.
You can input numbers in this box from 1 to 65535, reflecting 0% (1) to 100% (65535).
If Frequency is set to 0, no more of this object will appear during play of this level.
Min Count  Here you can set the minimum number of the object appearing in the level at one time.
Max Count  Likewise, here you set the maximum number of the object appearing in the level at one time.
For Example, let's say that you only want one Tozt to be in your level at any given time, but you want that Tozt to immediately become available again where it was originally placed as soon as the player with it dies.  So, in the Edit Object Placement Data dialog box, you would select 'Tozt' and set the Max count to 1, the Min count to 1, and the Frequency to 65535.
Likewise, if you wanted the Tozt to be available once and only once, you would set the Min Count to 0, the Max Count to 1, and the Frequency to 1.
Note  You are limited to a miximum number of 256 objects in a single level.  That includes players, monsters, weapons, ammo, and scenery.
Aliens
The word 'Aliens' in Marathon refers to any self-mobile object which is not you or another player.  This includes the B.O.B.';s, as well as the dreaded Pfhor.
Placement and number of the Aliens can be crucial to the challenge and strategy of a solo level, but is usually less important when creating network levels.  For example, if creating a solo level, if the magnum is the only weapon available to the player, and there are 100 hulks in the room where the player starts, chances are that this level will not be very enjoyable for the player (or challenging for the Hulks!).
Also remember that aliens in Marathon have a certain degree of 'intelligence.'  Once they 'see' a player, some aliens will chase him, some will immediately attack, and others will ignore him.  These settings are defined within the Marathon 'Physics Model', which can also be edited using other programs.
Aliens have the ability to be viewed from many angles, but you should face them towards where the player is likely to be so they can see the player and attack immediately.
Lighting
You can have up to 16 different lighting types.  With clever placement of polygons you can make it seem as if a light is shining through a doorway or window.  Lighting also helps to set the mood of the game.  Having everything brightly lit is not as exciting as having dimly lit rooms where aliens could be hiding.
The Lighting types are as follows
Normal Always at minimum light level.  Turns on and off instantly.
Rheostat Always at minimum light level.  Turns on and off slowly.
Flourescent Always at minimum light level.  Turns on and off flickering.
Strobes Strobes up and down from minimum to maximum.  Turns on and off instantly.
Flicker Randomly chooses a value minimum to maximum, each change coming at the defined period.  Turns on and off instantly.
Pulsates intensity=(max-min)/2+(max-min)*sin(phase)/2.  Turns on and off instantly.
Annoying Flickers in a rapid and disgusting manner.  Turns on and off instantly.
Energy Efficient Acts like rheostat, except every 30 seconds it checks if someone is in the light source and if not it turns the light off.
Scripting
Pfhorte! v1.019 now has a scripting system that you can use to speed up desing on your level.  Using the scripts, you can 'code' short subprograms or commands for Pfhorte! which can be used to abbreviate tedious or repetetive taske, much like the items already found in the magic menu.
To script in Pfhorte, you simply write a string of text commands from the list below to tell Phorte how to draw.  You tell Pfhorte where to start the point, how far to draw, what characteristics polys and such will have, and so on.
The next version of the documentation will have much more detail in this section, however, for right now, here's some commands to get you started.
If you have any suggestions for additional commands or features for the scripting system, please let me know.  If you have any useful scripts you want to have included into Pfhorte you can e-mail them to me an I will evaluate them for inclusion into the next version.

Basics
All scripts operate on the currently selected line in the map window.  They do not have to make use of this line, but they should.  The scripting system has the concept of a pen.  You can move the pen around and cause walls to be created forming a new polygon.  The pen starts out on the first point (clockwise) on the selected line with its angle set to point towards the second point.  Angles are from 0 - straight up, clockwise to 360 degrees.  From this starting position it is up to your script to do something interesting.  It is recommended that you examine and understand all the scripts that come with Pfhorte before writing your own.  Currently no errors are reported, the script will just quietly stop at the error, so debugging could be tough.  All script command must appear on a new line, with only one command per line.  Spelling and capitalization are important.

Here are the commands and what they do

splitLine		Splits the current line in half.  The new current line is the first half.
segmentLine n	Adds an n sized segment to the center of the selected line.  
				Becomes the current line.
turn n		Turns the pen by n degrees clockwise.
newLine n		Creates a new wall from the current point in the direction of the 
				current angle n units long.
closePoly		Creates a new line from the current point to the first point in the 			poly.
height n		Sets the ceiling height to the floor height plus n.
ceilingHeight n	Changes the ceiling height by n units.
floorHeight n	Changes the floor height by n units.
polyType m	Sets the default polygon type to m. See the list of polytypes below.
wallType m	Sets the wall type for the next wall to m. This is for control panels.
				See the list below for the wall types.
pushPen		Saves the current pen position and angle.
popPen		Returns to the last saved pen position and angle.
pushLine		Saves the current line.
popLine		Returns to the last saved line and makes it the selected line.
  				ClosePoly must have been called first.  Also makes a point at the 			first point.
move n		Moves the pen n units without creating a wall.
makeLine		Creates a new wall from the last point to the current pen position.
*				The rest of the line is ignored, this is handy for adding comments.
firstPoint		Moves the pen to the first point on the selected line.
lastPoint		Moves the pen to the last point on the selected line.
repeat n		Repeats the next statements n times. n is optional.
endRepeat		End of the repeated statements.
until s		End of repeated statements. s = a conditional end.  Can check
				for floor/ceil height.  Use the constants FloorPassedDefault, 
				CeilingPassedDefault
moveCeiling n	Moves the ceiling by n units towards the default ceiling height.
moveFloor n	Moves the floor by n units towards the default floor height.

Constants to be used in place of n
LineLength		This is the length of the selected line, use in place of n.
StairSize		This is the defaults palette setting, use in place of n.
LeftSize		This is the defaults palette setting, use in place of n.
RightSize		This is the defaults palette setting, use in place of n.

Polygon types
Normal
ItemImpassable
MonsterImpassable
MinorDamage
MajorDamage
Platform
LightOnTrigger
PlatformOnTrigger
LightOffTrigger
PlatformOffTrigger
Teleporter
Glue
GlueTrigger
SuperGlue
MustExplore
Exit

Wall Types
Oxygen
Recharge1
Recharge2
Recharge3
LightSwitch
PlatformSwitch
PatternBuffer
unused type
Terminal
RepairSwitch
AlienRecharge2
AlienRecharge3
AlienPlatformSwitch
AlienPatternBuffer

Sample scripts
"MakeDoor" script
* This script is Copyright 1995 by Steve Israelson
* Segments a line and then adds a small polygon
* to that line segment, and turns it into a door
*
polytype Platform
segmentline 1024
turn -90
newline 128
turn 90
newline 1024
lastpoint
makeline
closepoly

"MakePentagon" script
* This script is Copyright 1995 by Steve Israelson
* Makes a Pentagon hallway.  Tests repeat code
*
segmentline 1024
turn -108
repeat 3
newline 1024
turn 72
endrepeat
lastpoint
makeline
closepoly

Preferences
The preferences file saves the current positions of the palettes and the map editing window, as well as some of the menu settings like snap to grid etc, and also all the settings made in the prefereces dialog.
This section will be fully completed in the next version of the Pfhorte! documentation.
Appendices
Apendix I  Misc. Marathon Engine Limitations
No more than 8 points per polygon
No defining polygons in a counter-clockwise fashion. Polygon points must always go clockwise.
NO internal angles greater than 180 degrees or less than 15 degrees. (In other words, no REALLY thin polygons or concave polygons)
Avoid rooms larger than about 10,000 unitsthey start smearing and looking funny at this size. Solve this by making your rooms somewhat "twisty," like the long running areas in 'Colony Ship For Sale'.
No ceilings higher than 32767, no floors lower than -32767. 
No more than 256 polys, and no fewer than 2 polygons in a single map 
No more than 32 platforms in a single map
No more than 32 lighting types in a single map
No more than 256 sprites (aliens, weapons, players, scenery, ammo, etc.) in a single map
No more than 64 types of sprites in a single map. This isn't likely unless you put one of everything in.
Appendix II  General Tips
Put an alias to your shapes file in the same folder as Pfhorte!.
Always create polys by clicking in a clockwise direction.
Always set the defaults palette up, even before opening your map file.
Do not forget to add a player object to your map before testing it.
Expect marathon to crash when you test your custom maps, so make your maps in small steps so you can figure out what went wrong.  If you cannot trace the problem, please Email Steve Israelson or Randy Varnell with the bug so that a fix may be implemented.
After selecting Begin New Game in Marathon, ignore the dialog Marathon gives you about non-Bungie map packs.  Also, its not a good idea to let Marathon go into demo mode (letting the game sit for more than two minutes) with a custom Map pack loaded.  And, when playing network games, don't read the game stats for too long at the endMarathon will crash!
Do not have more than one poly join another all along one side, since this causes problems.
Start with the tutorial, then design Rome in a day.
Legal Junk
Marathon is a trademark of Bungie Inc.  Bungie is in no way responsible for Pfhorte, or effects that Pfhorte might have on Marathon, or your computer.